package com.moli.iov.sys.service.impl;

import com.moli.iov.sys.model.po.mongodb.LoginLog;
import com.moli.iov.sys.repositories.LoginLogDao;
import com.moli.iov.sys.service.ILoginLogService;
import com.moli.iov.util.SnowflakeUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 登录日志
 * </p>
 *
 * @author zql
 * @since 2019/9/26 16:35
 */
@Service
public class LoginLogServiceImpl implements ILoginLogService {

  @Autowired
  private LoginLogDao loginLogDao;

  @Override
  public void save(LoginLog loginLog) {
    loginLog.setId(SnowflakeUtils.getId());
    loginLogDao.save(loginLog);
  }
}
